'''
Created on Jan 25, 2012

@author: TeFa
'''
from podnapisi_api import Api
from getpass import getpass

podApi = Api("SubSearch")
username = raw_input("# Username: ")
password = getpass("# Password: ") 
login = podApi.login(username,password)
print login
if login == 200:
    podApi.initSubsFromServer("Prison Break")
    print podApi.nextSearchPage()
    print podApi.downloadSub(["133452"])